package com.wangcanxuan.www.service;

import com.wangcanxuan.www.annotation.Transaction;
import com.wangcanxuan.www.entity.dto.ResultInfo;

/**
 * 点赞业务类
 *
 * @author HHLJ
 * @date 2022/04/08
 */
public interface LikeService {

    /**
     * 实现点赞业务
     *
     * @param userId      用户id
     * @param likedUserId 被点赞用户的id
     * @return {@link ResultInfo}<{@link ?}>
     */
    @Transaction
    ResultInfo<String> likePeople(String userId, String likedUserId);

    /**
     * 实现获得用户当前点赞数的业务
     *
     * @param userId 用户id
     * @return {@link ResultInfo}<{@link Long}>
     */
    ResultInfo<Long> selectLikesForUser(String userId);
}
